package mjc.egg;
import mjc.compiler.*;
import mjc.gc.*;
import mg.egg.eggc.compiler.libjava.lex.*;
import mg.egg.eggc.compiler.libjava.messages.*;
import mg.egg.eggc.compiler.libjava.*;
import mg.egg.eggc.compiler.libjava.problem.IProblem;
import java.util.Vector;
public class S_T_MJAVA {
LEX_MJAVA scanner;
  S_T_MJAVA() {
    }
  S_T_MJAVA(LEX_MJAVA scanner) {
    this.scanner = scanner;
    this.att_scanner = scanner;
    }
int [] sync= new int[0];
  boolean att_isVariable;
  TDS att_htdsclasses;
  TDS att_htdsvarlocales;
  INFOCLASSE att_hinfoclasse;
  DTYPE att_type;
  LEX_MJAVA att_scanner;
  private void regle52() throws Exception {

    //declaration
    S_F_MJAVA x_2 = new S_F_MJAVA(scanner) ;
    S_TX_MJAVA x_3 = new S_TX_MJAVA(scanner) ;
    //appel
      action_auto_inh_52(x_2, x_3);
    x_2.analyser() ;
    x_3.analyser() ;
      action_action_52(x_2, x_3);
      action_typage6_52(x_2, x_3);
  }
private void action_auto_inh_52(S_F_MJAVA x_2, S_TX_MJAVA x_3) throws Exception {
try {
// instructions
x_2.att_htdsvarlocales=this.att_htdsvarlocales;
x_3.att_htdsvarlocales=this.att_htdsvarlocales;
x_2.att_htdsclasses=this.att_htdsclasses;
x_3.att_htdsclasses=this.att_htdsclasses;
x_2.att_hinfoclasse=this.att_hinfoclasse;
x_3.att_hinfoclasse=this.att_hinfoclasse;
}catch(RuntimeException e) {		//e.printStackTrace();
       scanner._interrompre(IProblem.Internal, scanner.getBeginLine(), ICoreMessages.id_EGG_runtime_error, CoreMessages.EGG_runtime_error,e.getStackTrace());
	}
  }
private void action_action_52(S_F_MJAVA x_2, S_TX_MJAVA x_3) throws Exception {
try {
// instructions
this.att_isVariable=x_3.att_isVariable&&x_2.att_isVariable;
}catch(RuntimeException e) {		//e.printStackTrace();
       scanner._interrompre(IProblem.Internal, scanner.getBeginLine(), ICoreMessages.id_EGG_runtime_error, CoreMessages.EGG_runtime_error,e.getStackTrace());
	}
  }
private void action_typage6_52(S_F_MJAVA x_2, S_TX_MJAVA x_3) throws Exception {
try {
// instructions
if (x_3.att_type.compareTo( new DTYPE("void", 0))){
this.att_type=x_2.att_type;
}
else {
if (x_3.att_type.compareTo(x_2.att_type)){
this.att_type=x_2.att_type;
}
else {
att_scanner._interrompre(IProblem.Semantic, att_scanner.getBeginLine(), IMJAVAMessages.id_MJAVA_type_error, MJAVAMessages.MJAVA_type_error,new Object[]{""+x_3.att_type.toString(), ""+x_2.att_type.toString()});

}
}
}catch(RuntimeException e) {		//e.printStackTrace();
       scanner._interrompre(IProblem.Internal, scanner.getBeginLine(), ICoreMessages.id_EGG_runtime_error, CoreMessages.EGG_runtime_error,e.getStackTrace());
	}
  }
  public void analyser () throws Exception {
    regle52 () ;
  }
  }
